package com.itheima.day02.Test03;

import java.util.concurrent.CountDownLatch;

public class Test {
    public static void main(String[] args) {

        CountDownLatch countDownLatch = new CountDownLatch(3);
        MotherThread motherThread = new MotherThread(countDownLatch);
        ChildrenThread01 t1 = new ChildrenThread01(countDownLatch);

        ChildrenThread02 t2 = new ChildrenThread02(countDownLatch);
        ChildrenThread03 t3 = new ChildrenThread03(countDownLatch);
        t1.setName("小明");
        t2.setName("小红");
        t3.setName("小强");
        t1.start();
        t2.start();
        t3.start();
    }
}
